home *** CD-ROM | disk | FTP | other *** search
/ Aminet 25 / Aminet 25 (1998)(GTI - Schatztruhe)[!][Jun 1998].iso / Aminet / dev / amos / AMOS0398.lzh / AMOSLIST / 000248_amos-request@svcs1.digex.net_Wed Mar 25 18:24:37 1998.msg < prev    next >
Text File  |  1998-04-01  |  4KB  |  96 lines

  1. >From amos-request@svcs1.digex.net  Wed Mar 25 18:24:37 1998
  2. Received: from svcs1.digex.net (svcs1.digex.net [204.91.197.224])
  3.     by pony-1.mail.digex.net (8.8.8/8.8.8) with ESMTP id SAA11272
  4.     for <mcox@access.digex.net>; Wed, 25 Mar 1998 18:24:36 GMT
  5. Received: (from daemon@localhost)
  6.     by svcs1.digex.net (8.8.5/8.8.5) id KAA27124
  7.     for amos-out; Wed, 25 Mar 1998 10:38:02 -0500 (EST)
  8. Received: from pony-2.mail.digex.net (pony-2.mail.digex.net [204.91.241.6])
  9.     by svcs1.digex.net (8.8.5/8.8.5) with ESMTP id KAA27121
  10.     for <amos-list@svcs1.digex.net>; Wed, 25 Mar 1998 10:38:01 -0500 (EST)
  11. Received: from orca.ucd.ie (orca.ucd.ie [137.43.4.16])
  12.     by pony-2.mail.digex.net (8.8.8/8.8.8) with SMTP id KAA22985
  13.     for <amos-list@access.digex.net>; Wed, 25 Mar 1998 10:37:45 -0500 (EST)
  14. Received: (qmail 29122 invoked by uid 1514); 25 Mar 1998 15:37:42 -0000
  15. Date: Wed, 25 Mar 1998 15:37:42 +0000 (GMT)
  16. From: Matt <mattw@orca.ucd.ie>
  17. To: Amos-List <amos-list@access.digex.net>
  18. Subject: Re: extension?
  19. In-Reply-To: <1907.376T767T9082936@bahnhof.se>
  20. Message-ID: <Pine.LNX.3.96.980325153423.27830A-100000@orca.ucd.ie>
  21. MIME-Version: 1.0
  22. Content-Type: TEXT/PLAIN; charset=US-ASCII
  23. Status: O
  24. X-Status: 
  25.  
  26. On 13 Mar 1998, Jonas Thorell wrote:
  27.  
  28. > Garfield Benjamin (gbenjam@sosbbs.com) wrote:
  29. > >> If AGE<10
  30. > >>    Print "You are less than 10 years old."
  31. > >> else if AGE=21
  32. > >>    Print "Hey!! Now you can drink alcohol in the U.S.!!"
  33. > >> else
  34. > >>    Print "WOW, you're OVER 21!!"
  35. > >> endif
  36. > >> Smallest, and tidiest in my humble opinion.
  37. > >> Is my approach good enough in the meantime?
  38. > >   Well, problem is this won't work. 
  39. > Yes it will. I tried it.
  40. > >First, you need to match every If with an End If and second, the logic is not 
  41. > >the same.
  42. > Both. If and endif is coupled the same way as select ... case ... endselect
  43. > is so I can't see the problem. The logic is the same too. Select..is just
  44. > more advanced in that it offers some extra features.
  45. > >If AGE<10
  46. > >   Print "You are less than 10 years old."
  47. > >Else If AGE=21
  48. > >      Print"Hey!! Now you can drink alcohol in the U.S.!!"
  49. > >   Else If AGE>21
  50. > >         Print "WOW, you'r OVER 21!!"
  51. > >      End If
  52. > >   End If
  53. > >End If
  54. > That would trigger the error-system. One if and three end-ifs is plain
  55. > wrong.
  56. > >   That being said, this might be a bit clearer (arguably the "best"
  57. > >   method for AMOS) but it still lacks when compared to the
  58. > >   Select...Case style.  Anyway, the point is you are still looking at
  59. > >   the same two basic methods, the If...End If and the If...Else...EndIf
  60. > Yes but does it really matter? The result is what is importand and the
  61. > if...
  62. > else if ...
  63. > else
  64. > end if
  65. > structure is quite close to the select.. syntax.
  66. Hi, I just got to my email after a few weeks off and this is near the
  67. top of the bundle ... It's probably answered later on tho...
  68. Didn't one of the updates to Amos/Pro fix the Elseif etc prob? So
  69. although messy some older versions can only use the Second approach. I
  70. remember this change cos at the time I thought that Amos code
  71. sometimes looked ridiculous with all the indenting.....
  72.  
  73. ###       ###  ########  ########### ###########
  74. ####     #### ###    ###     ###         ###
  75. ##!##   ##!## #!#    #!#     #!#         #!#
  76. !#! #!#!# !@! !@!!@@!!@!     !@!         !@!     mattw@netsoc.ucd.ie
  77. !!!   !   !!! !!!    !!!     !!!         !!!            x  x
  78. :!:       :!: :!:    :!:     :!:         :!:            \__/
  79. :::       ::: :::    :::     :::         :::  
  80. ::         :: ::     ::       :           :
  81.